Not Applicable.
Not Applicable.
This invention relates to computer-readable codes such as barcodes, and more particularly to methods and apparatus for scanning codes from an electronic display or screen.
Barcodes provide a quick and convenient method of reliably entering information into a computer or computer system by scanning the barcode. They have become very common on a wide variety of consumer goods and services. An example of when a barcode is used with a service is when a barcode is printed on a membership card. Some barcodes are printed on packaging, such as barcodes indicating the universal product code (xe2x80x9cUPCxe2x80x9d) of an item, and others are unique, such as a barcode printed on a parking garage ticket that indicates the date and time of when the ticket was taken. The data in the barcode is generally represented as a pattern of two levels of surface reflectivity, such as black and white stripes for a one-dimensional barcode. Two-dimensional barcodes also use a pattern of alternating reflectivities, but in a pattern of squares or other shapes. In either event, the data contained in the barcode is coded according to a binary coding system and the light and dark areas are interpreted as 1""s and 0""s or vice versa.
Barcodes are typically scanned by a scanner or reader (hereinafter xe2x80x9creaderxe2x80x9d). One type of reader has a lamp that uniformly illuminates the barcode, and an imaging sensor, such as a charge-coupled device (xe2x80x9cCCDxe2x80x9d) array, CMOS detector, or other electronic imaging method, that detects the scattered light that is reflected off the barcode. Dark ink on light paper is a typical medium for presenting barcodes. The dark ink or paint provides low-reflectivity regions, and the light colored or matte (light scattering) paper provides high-reflectivity regions. Of course, one may use light paint on a dark background.
Another type of reader builds a map of surface reflectivity by rastering a laser beam over the surface. A single photodiode detects the light reflected from each position of the laser spot on the surface. This type of barcode reader is called a laser barcode scanner.
Unfortunately, neither approach is currently well-adapted to reading barcode images displayed on information display screens, such as the display screen of a wireless telephone (xe2x80x9ccell phonexe2x80x9d) or personal digital assistant (xe2x80x9cPDAxe2x80x9d). Rendering a barcode on a display of a cell phone or PDA would be desirable because it would relieve the consumer from needing to carry the bits of paper usually associated with tickets and coupons, for example.
Display screens can be divided into two classes, reflective and emissive. Reflective screens are broadly defined as screens that alter their reflectivity of ambient light to form an image, typically from light and dark pixels, such as passive black and white liquid crystal displays (xe2x80x9cLCDsxe2x80x9d). Emissive screens, such as backlit LCDs and cathode ray tubes (CRTsxe2x80x9d) internally generate the light emitted from their surface. Conventional laser barcode scanners do not work well with emissive display screens because the emissive displays do not necessarily change their surface reflectivity with image content. Imaging scanners may be able to read both types of screens, but might have difficulty with reflections off the surface of the display and insufficient contrast between the light and dark portions of the scannable code.
One reason reflective display screens do not work well with conventional barcode readers is that the reflective display screens are typically designed with the assumption that little light will be incident from the direction of the viewer. In normal use the viewer""s head will block light from this direction. Therefore, screens are often built without antireflection coatings on the front surface or at internal optical interfaces.
However, the light source built into laser barcode scanners typically projects bright light from the direction of the camera or photodiode(s). This causes reflections in the image observed by the camera that can interfere with the displayed image. In addition, the overall light levels of barcodes displayed on reflective screens are different than for normal barcodes. For example, LCDs have internal polarizers that reflect a much smaller fraction of incident light than a painted or white paper surface. To the scanner, both light and dark pixels may appear dark.
Emissive screens may be easier for barcode scanners to read; however, they too may have compatibility problems. Emissive screens often have a diffusing front coating or surface treatment of the glass to reduce specular reflection of ambient light. Illuminating emissive screens with the lamps on a barcode scanner adds a scattered light background component to the light emitted from the screen. This background of scattered light reduces the contrast between light and dark pixels. Additionally, specular reflections of the light from the barcode scanner lamp to the camera or photodiode(s) can interfere with scanning as with reflective display screens.
If a barcode reader can""t scan the barcode the first time, it typically tries again and again. Often, the scanning fails and the clerk must take additional time to enter the data that would have otherwise been scanned into the computer.
Therefore, a barcode reader that can quickly and reliably scan codes rendered on an electronic display screen is desirable. It is further desirable that the barcode scanner be able to read codes from emissive or reflective screens.
A barcode reader uses an imaging technique to quickly and accurately scan barcodes rendered on electronic displays. A shade on the barcode reader blocks ambient light from the CCD imager (xe2x80x9ccameraxe2x80x9d) and configures the barcode reader illumination to be off-normal from the surface of the display. A variety of CCD cameras are available from a variety of vendors, such as cameras sold under the trade name MEGAFILL(trademark) by KODAK. The light detector array is typically integrated with on-chip electronics for interfacing the camera to an instrument. In one embodiment, a CCD array with a 640 by 480 pixel detector array was used with a fill factor greater than 80%; however, it is possible to use cameras with lower fill factors and fewer elements to read two-dimensional barcodes, especially if software filtering methods are used to enhance the image. The barcode reader can detect light emitted from the display to turn off scanner illumination, thus avoiding interference between the emitted light and the scanner light and specular reflections of the scanner light into the camera.
In a further embodiment, the exposure time of the CCD camera is set to between 2-20 times the vertical refresh period of a display. In a yet further embodiment, the refresh rate of the display is detected by the barcode reader and the exposure time of the CCD camera is adjusted accordingly to between 2-20 times the measured refresh rate. This enhances accuracy of the scan by reducing errors caused by the display flicker.
The CCD imager uses automatic exposure or gain to optimize image contrast. In a particular embodiment, decoder software is used to set the detection threshold of the CCD camera. In an alternative or further embodiment, the scanner illumination is adjusted to achieve the desired contrast. In another embodiment, a CCD array with a wide spectral response is used to reduce or avoid Moirxc3xa9 patterns from color pixels.
In another embodiment, the barcode scanner adjusts scaling in response to displays with non-square pixels. In a particular embodiment an initial scan determines if a two-dimensional barcode is rendered as the standard pattern of squares, or as a pattern of rectangles arising from rectangular display pixels. The scanner alters the horizontal-vertical scaling to interpret the displayed rectangles as appropriate barcode elements.